<!DOCTYPE html>
<html>

	<head>
		<meta charset="utf-8" />
		<title></title>
		<script type="text/javascript" src="js/jquery-1.12.4.js"></script>
		<script type="text/javascript" src="js/test.js"></script>
		<style>
			.d {
				width: 800px;
				height: 800px;
			}
			.d1{
				width: 300px;
				height: 300px;
				display: inline-block;
			}
			.d2 {
				width: 300px;
				height: 300px;
				display: inline-block;
				overflow: hidden;
			}
			.d21 {
				width: 100px;
				height: 100px;
				
			}
			.d22 {
				width: 100px;
				height: 100px;
				
			}
			/*也应当在父层用 overflow:hidden*/
		</style>
		<script type="text/javascript">
			$(function() {
				init();
			})
		</script>
	</head>

	<body>
		<div class="d">
			<div class="d1">
				
			</div>
			<div class="d2">
				<div class="d3">
					<div class="d21">
						ggfghfhfhfhhf
					</div>
					<div class="d22">
						fghfghfhfhfhf
					</div>
				</div>
			</div>
		</div>
	</body>

</html>